-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP] Added new create-poll button in post drafting interface (no forms linked yet) #43
Conversation
…dded into the system
…es, and categories
…utton now shows up
I took a look at your changes and tested your code on my laptop. This works fine on my end! |
'groups:ban', 'groups:upload:post:file', 'create-poll']), 'Global Moderators'); | ||
await privileges.global.give(['groups:view:users', 'groups:view:tags', 'groups:view:groups', 'create-poll'], 'guests'); | ||
await privileges.global.give(['groups:view:users', 'groups:view:tags', 'groups:view:groups', 'create-poll'], 'spiders'); | ||
await privileges.global.give(['groups:view:users', 'groups:view:tags', 'groups:upload:post:file', 'groups:view:groups', 'create-poll'], 'Instructors'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jwjulie can you review this and see if these changes will break anything (I don't think they will but I'm also not 100% sure if this is necessary). I was attempting to add create-poll as a privilege to all the current roles. 😆 ❤️ ☮️ ✌️
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good! Adding the create-polls privilege should not cause issues with anything I have implemented.
Yuki and I talked with multiple TAs and instructors and received different responses across the entire group, so we were not able to figure out how to commit our front end changes! |
Pull Request Test Coverage Report for Build 13274577043Warning: This coverage report may be inaccurate.This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.
Details
💛 - Coveralls |
WIP Explanation
The frontend button is working, but the only thing making this issue an "WIP" is our issues with node_module files. Read Testing & Validations for further explanation.
Context
Resolved specific task issue #37 and addresses parent issue #32 by creating a hover-able button in the post drafting interface. Addresses the user story for polls/surveys in P1A.
Description
Created a button with polls icon imported from font awesome icon library. This button shows up next to the upload-file button for admin and next to the upload-image button for all other users due to privilege constraints. Dependent on Instructors group created in add-role-groups branch (criteria cleared and was installed when working on this feature).
When clicked, there is no prompt for the polls yet and the preview + backend aggregation have not been set up yet. This will be implemented in sprint 2 by @yukiiii04 & @lynzhlang .
Codebase Changes
./public/language/en-US/admin/manage/categories.json
: define create-poll as a category management setting./public/language/en-US/admin/manage/privileges.json
: adds create-poll as a new user privilege./public/language/en-US/modules.json
: adds create-poll to the composer module./node_modules/nodebb-plugin-composer-default/static/templates/partials/composer-formatting.tpl
: this is the partial that is reused when making post draft. Edited so that new list item (create-poll button) is included in template..gitignore
: unignore the specific file we want to commitTesting & Validations
**Next step: ** @lynzhlang is joining me to work on the these #38 , #39 , #40 . The goal is to get this feature implemented and tested by Saturday, February 22nd.
Current progress
